import Vue from 'vue'
//引入websocket文件
import wsRequest from './websocket.js'
export default {
	openws(id) {
		console.log("进来啦ws")
		//开启websocket
		let websocket = new wsRequest("ws://127.0.0.1:8080/websocket/"+id, 5000)
		//挂载到全局
		Vue.prototype.$socket = websocket
	}
}